#ifndef MLOADER_MESH
#define MLOADER_MESH

#include "Common.h"

namespace MLoader
{
    struct Bone
    {
        // Vertex Index, Vertex Weight [0, 1]
        typedef std::pair<int, float> Weight;
        
        std::string Name;
        
        gm::Mat4 Transform; // Mesh space to the local space of this bone
        std::vector<Weight> Weights;
    };

    struct Mesh
    {
        std::string Name;

        int MaterialID;
        std::vector<Bone> Bones;
        std::vector<gm::Vec2> TexCoords;
        std::vector<gm::Vec3> Normals;
        std::vector<gm::Vec3> Tangents;
        std::vector<gm::Vec3> Bitangents;
        std::vector<gm::Face> Faces;
        std::vector<gm::Vec4> Positions;
        std::vector<gm::Vec4> Colors;
    };
}


#endif // MLOADER_MESH
